<!DOCTYPE html>
<html lang="zh-CN">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <meta name="robots" content="noodp" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge, chrome=1">
        <title>Trojan-go搭建 - 海蓝的博客</title><meta name="Description" content="运维搬砖"><meta property="og:title" content="Trojan-go搭建" />
<meta property="og:description" content="使用trojan-go进行搭建。" />
<meta property="og:type" content="article" />
<meta property="og:url" content="https://guohailan.github.io/trojan-go%E6%90%AD%E5%BB%BA/" /><meta property="og:image" content="https://guohailan.github.io/logo.png"/><meta property="article:section" content="posts" />
<meta property="article:published_time" content="2021-01-23T20:17:13&#43;00:00" />
<meta property="article:modified_time" content="2021-01-23T20:17:13&#43;00:00" />

<meta name="twitter:card" content="summary_large_image"/>
<meta name="twitter:image" content="https://guohailan.github.io/logo.png"/>

<meta name="twitter:title" content="Trojan-go搭建"/>
<meta name="twitter:description" content="使用trojan-go进行搭建。"/>
<meta name="application-name" content="LoveIt">
<meta name="apple-mobile-web-app-title" content="LoveIt"><meta name="theme-color" content="#ffffff"><meta name="msapplication-TileColor" content="#da532c"><link rel="shortcut icon" type="image/x-icon" href="/favicon.ico" />
        <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
        <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"><link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"><link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5"><link rel="manifest" href="/site.webmanifest"><link rel="canonical" href="https://guohailan.github.io/trojan-go%E6%90%AD%E5%BB%BA/" /><link rel="prev" href="https://guohailan.github.io/trojan%E6%90%AD%E5%BB%BA/" /><link rel="stylesheet" href="/lib/normalize/normalize.min.css"><link rel="stylesheet" href="/css/style.min.css"><link rel="stylesheet" href="/lib/fontawesome-free/all.min.css"><link rel="stylesheet" href="/lib/animate/animate.min.css"><script type="application/ld+json">
    {
        "@context": "http://schema.org",
        "@type": "BlogPosting",
        "headline": "Trojan-go搭建",
        "inLanguage": "zh-CN",
        "mainEntityOfPage": {
            "@type": "WebPage",
            "@id": "https:\/\/guohailan.github.io\/trojan-go%E6%90%AD%E5%BB%BA\/"
        },"genre": "posts","keywords": "torjan","wordcount":  2981 ,
        "url": "https:\/\/guohailan.github.io\/trojan-go%E6%90%AD%E5%BB%BA\/","datePublished": "2021-01-23T20:17:13+00:00","dateModified": "2021-01-23T20:17:13+00:00","license": "This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.","publisher": {
            "@type": "Organization",
            "name": "","logo": "https:\/\/guohailan.github.io\/images\/avatar.png"},"author": {
                "@type": "Person",
                "name": "guohailan"
            },"description": ""
    }
    </script></head>
    <body header-desktop="fixed" header-mobile="auto"><script type="text/javascript">(window.localStorage && localStorage.getItem('theme') ? localStorage.getItem('theme') === 'dark' : ('auto' === 'auto' ? window.matchMedia('(prefers-color-scheme: dark)').matches : 'auto' === 'dark')) && document.body.setAttribute('theme', 'dark');</script>

        <div id="mask"></div><div class="wrapper"><header class="desktop" id="header-desktop">
    <div class="header-wrapper">
        <div class="header-title">
            <a href="/" title="海蓝的博客"><span class="header-title-pre"><i class='far fas fa-blog fa-fw'></i></span><span id="id-1" class="typeit"></span></a>
        </div>
        <div class="menu">
            <div class="menu-inner"><a class="menu-item" href="/posts/"> 所有文章 </a><a class="menu-item" href="/tags/"> 标签 </a><a class="menu-item" href="/categories/"> 分类 </a><a class="menu-item" href="https://github.com/guohailan" title="GitHub" rel="noopener noreffer" target="_blank"><i class='fab fa-github fa-fw'></i>  </a><span class="menu-item delimiter"></span><span class="menu-item search" id="search-desktop">
                        <input type="text" placeholder="搜索文章标题或内容..." id="search-input-desktop">
                        <a href="javascript:void(0);" class="search-button search-toggle" id="search-toggle-desktop" title="搜索">
                            <i class="fas fa-search fa-fw"></i>
                        </a>
                        <a href="javascript:void(0);" class="search-button search-clear" id="search-clear-desktop" title="清空">
                            <i class="fas fa-times-circle fa-fw"></i>
                        </a>
                        <span class="search-button search-loading" id="search-loading-desktop">
                            <i class="fas fa-spinner fa-fw fa-spin"></i>
                        </span>
                    </span><a href="javascript:void(0);" class="menu-item theme-switch" title="切换主题">
                    <i class="fas fa-adjust fa-fw"></i>
                </a>
            </div>
        </div>
    </div>
</header><header class="mobile" id="header-mobile">
    <div class="header-container">
        <div class="header-wrapper">
            <div class="header-title">
                <a href="/" title="海蓝的博客"><span class="header-title-pre"><i class='far fas fa-blog fa-fw'></i></span><span id="id-2" class="typeit"></span></a>
            </div>
            <div class="menu-toggle" id="menu-toggle-mobile">
                <span></span><span></span><span></span>
            </div>
        </div>
        <div class="menu" id="menu-mobile"><div class="search-wrapper">
                    <div class="search mobile" id="search-mobile">
                        <input type="text" placeholder="搜索文章标题或内容..." id="search-input-mobile">
                        <a href="javascript:void(0);" class="search-button search-toggle" id="search-toggle-mobile" title="搜索">
                            <i class="fas fa-search fa-fw"></i>
                        </a>
                        <a href="javascript:void(0);" class="search-button search-clear" id="search-clear-mobile" title="清空">
                            <i class="fas fa-times-circle fa-fw"></i>
                        </a>
                        <span class="search-button search-loading" id="search-loading-mobile">
                            <i class="fas fa-spinner fa-fw fa-spin"></i>
                        </span>
                    </div>
                    <a href="javascript:void(0);" class="search-cancel" id="search-cancel-mobile">
                        取消
                    </a>
                </div><a class="menu-item" href="/posts/" title="">所有文章</a><a class="menu-item" href="/tags/" title="">标签</a><a class="menu-item" href="/categories/" title="">分类</a><a class="menu-item" href="https://github.com/guohailan" title="GitHub" rel="noopener noreffer" target="_blank"><i class='fab fa-github fa-fw'></i></a><a href="javascript:void(0);" class="menu-item theme-switch" title="切换主题">
                <i class="fas fa-adjust fa-fw"></i>
            </a></div>
    </div>
</header>
<div class="search-dropdown desktop">
    <div id="search-dropdown-desktop"></div>
</div>
<div class="search-dropdown mobile">
    <div id="search-dropdown-mobile"></div>
</div>
<main class="main">
                <div class="container"><div class="toc" id="toc-auto">
            <h2 class="toc-title">目录</h2>
            <div class="toc-content" id="toc-content-auto"></div>
        </div><article class="page single"><h1 class="single-title animated flipInX">Trojan-go搭建</h1><div class="post-meta">
            <div class="post-meta-line"><span class="post-author"><a href="/" title="Author" rel=" author" class="author"><i class="fas fa-user-circle fa-fw"></i>guohailan</a></span>&nbsp;<span class="post-category">收录于 <a href="/categories/%E4%B8%AD%E9%97%B4%E4%BB%B6/"><i class="far fa-folder fa-fw"></i>中间件</a></span></div>
            <div class="post-meta-line"><i class="far fa-calendar-alt fa-fw"></i>&nbsp;<time datetime="2021-01-23">2021-01-23</time>&nbsp;<i class="fas fa-pencil-alt fa-fw"></i>&nbsp;约 2981 字&nbsp;
                <i class="far fa-clock fa-fw"></i>&nbsp;预计阅读 6 分钟&nbsp;<span id="/trojan-go%E6%90%AD%E5%BB%BA/" class="leancloud_visitors" data-flag-title="Trojan-go搭建">
                        <i class="far fa-eye fa-fw"></i>&nbsp;<span class=leancloud-visitors-count></span>&nbsp;次阅读
                    </span>&nbsp;</div>
        </div><div class="featured-image"><img
        class="lazyload"
        src="/svg/loading.min.svg"
        data-src="/images/thumbnail/trojan-go.png"
        data-srcset="/images/thumbnail/trojan-go.png, /images/thumbnail/trojan-go.png 1.5x, /images/thumbnail/trojan-go.png 2x"
        data-sizes="auto"
        alt="/images/thumbnail/trojan-go.png"
        title="/images/thumbnail/trojan-go.png" /></div><div class="details toc" id="toc-static"  kept="">
                <div class="details-summary toc-title">
                    <span>目录</span>
                    <span><i class="details-icon fas fa-angle-right"></i></span>
                </div>
                <div class="details-content toc-content" id="toc-content-static"><nav id="TableOfContents">
  <ul>
    <li><a href="#什么是trojan-go">什么是Trojan-go</a></li>
    <li><a href="#域名准备">域名准备</a>
      <ul>
        <li><a href="#域名申请">域名申请</a></li>
        <li><a href="#域名测试">域名测试</a></li>
      </ul>
    </li>
    <li><a href="#证书申请">证书申请</a></li>
    <li><a href="#torjan-go搭建">Torjan-go搭建</a>
      <ul>
        <li><a href="#安装bbr加速">安装BBR加速</a></li>
        <li><a href="#一键安装trojan-go">一键安装trojan-go</a></li>
      </ul>
    </li>
    <li><a href="#cnd加速">CND加速</a>
      <ul>
        <li><a href="#cloudflare创建反代理加速">cloudflare创建反代理加速</a></li>
        <li><a href="#开启cdn并设置cdn">开启CDN，并设置CDN</a></li>
        <li><a href="#websocket开启">websocket开启</a></li>
        <li><a href="#windows客户端配置">windows客户端配置</a></li>
      </ul>
    </li>
    <li><a href="#windows配置">windows配置</a>
      <ul>
        <li><a href="#qv2ray及插件安装">Qv2ray及插件安装</a></li>
        <li><a href="#trojan-go核心下载">trojan-go核心下载</a></li>
        <li><a href="#v2ray-core下载">v2ray-core下载</a></li>
        <li><a href="#qv2ray配置">Qv2ray配置</a>
          <ul>
            <li><a href="#插件配置">插件配置</a></li>
            <li><a href="#v2ray-core配置">v2ray-core配置</a></li>
            <li><a href="#新建连接">新建连接</a></li>
          </ul>
        </li>
        <li><a href="#验证">验证</a></li>
      </ul>
    </li>
    <li><a href="#安卓配置">安卓配置</a></li>
    <li><a href="#相关软件">相关软件</a></li>
  </ul>
</nav></div>
            </div><div class="content" id="content"><p>使用trojan-go进行搭建。</p>
<h2 id="什么是trojan-go">什么是Trojan-go</h2>
<p>使用Go实现的完整Trojan代理，与Trojan协议以及Trojan版本的配置文件格式兼容。安全，高效，轻巧，易用。详见<a href="https://github.com/p4gefau1t/trojan-go" target="_blank" rel="noopener noreffer">官网</a></p>
<h2 id="域名准备">域名准备</h2>
<p>域名申请可以去腾讯云或者阿里云等国内大厂申请（缺点就是需要花钱），这里我是去的免费域名商freenom申请的<a href="http://www.freenom.com/zh/index.html" target="_blank" rel="noopener noreffer">http://www.freenom.com/zh/index.html</a>，不过访问这个地址很慢，所以可能需要提前出去。</p>
<h3 id="域名申请">域名申请</h3>
<p>首先注册账号，基本信息里实测国家选择<font color=#DC143C>美国</font>以外的地区可能无法注册成功，所以这里我选择的洛杉矶</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118221317622.png" title="/images/Trojan-go搭建/image-20210118221317622.png" data-thumbnail="/images/Trojan-go搭建/image-20210118221317622.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118221317622.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118221317622.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118221317622.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118221317622.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118221317622.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>输入希望申请的域名，点击检查可用性</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220651867.png" title="/images/Trojan-go搭建/image-20210118220651867.png" data-thumbnail="/images/Trojan-go搭建/image-20210118220651867.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220651867.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220651867.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220651867.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220651867.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118220651867.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>选择心仪的域名后缀，点击现在获取</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220757391.png" title="/images/Trojan-go搭建/image-20210118220757391.png" data-thumbnail="/images/Trojan-go搭建/image-20210118220757391.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220757391.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220757391.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220757391.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118220757391.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118220757391.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>域名时长我们一般选择最长时间1年，然后将VPS的IP填入解析地址（也可以现在不填，申请完成后在My Domains里面进行填写）</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222157926.png" title="/images/Trojan-go搭建/image-20210118222157926.png" data-thumbnail="/images/Trojan-go搭建/image-20210118222157926.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222157926.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222157926.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222157926.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222157926.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118222157926.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h3 id="域名测试">域名测试</h3>
<p>默认的DNS生效时间比较长，大概半小时左右。本地能ping通域名，返回的地址为希望的IP，表示域名申请成功</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222954624.png" title="/images/Trojan-go搭建/image-20210118222954624.png" data-thumbnail="/images/Trojan-go搭建/image-20210118222954624.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222954624.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222954624.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222954624.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118222954624.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118222954624.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h2 id="证书申请">证书申请</h2>
<p><strong><font color=#DC143C>一键搭建脚本可以自动申请证书（有效期3个月），证书申请步骤可以跳过</font></strong></p>
<p>证书申请也是本着不花钱的原则，选择<a href="https://freessl.cn/" target="_blank" rel="noopener noreffer">https://freessl.cn/</a></p>
<p>因为只有亚洲诚信可以支持双域名，而且有效期可以1年，所以选择亚洲诚信，点击创建免费的SSL证书</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223321305.png" title="/images/Trojan-go搭建/image-20210118223321305.png" data-thumbnail="/images/Trojan-go搭建/image-20210118223321305.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223321305.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223321305.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223321305.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223321305.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118223321305.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>填入个人邮箱，然后点击创建</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223513080.png" title="/images/Trojan-go搭建/image-20210118223513080.png" data-thumbnail="/images/Trojan-go搭建/image-20210118223513080.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223513080.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223513080.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223513080.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223513080.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118223513080.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>登录FreeSSL的账号，安装亚洲诚信的KeyManager</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223709924.png" title="/images/Trojan-go搭建/image-20210118223709924.png" data-thumbnail="/images/Trojan-go搭建/image-20210118223709924.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223709924.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223709924.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223709924.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223709924.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118223709924.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>点击继续后，会自动带起KeyManager，生成秘钥</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223957243.png" title="/images/Trojan-go搭建/image-20210118223957243.png" data-thumbnail="/images/Trojan-go搭建/image-20210118223957243.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223957243.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223957243.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223957243.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118223957243.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118223957243.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>回到浏览器，在浏览器上会提示DNS验证</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224709956.png" title="/images/Trojan-go搭建/image-20210118224709956.png" data-thumbnail="/images/Trojan-go搭建/image-20210118224709956.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224709956.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224709956.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224709956.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224709956.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118224709956.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>这时我们回到freenom点击My Domains，点击Manage Domain，选择Manage Freenom DNS</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224205751.png" title="/images/Trojan-go搭建/image-20210118224205751.png" data-thumbnail="/images/Trojan-go搭建/image-20210118224205751.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224205751.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224205751.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224205751.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224205751.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118224205751.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>将证书生成的信息填入DNS的解析里面，Type选择TXT，然后点击保存</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224559935.png" title="/images/Trojan-go搭建/image-20210118224559935.png" data-thumbnail="/images/Trojan-go搭建/image-20210118224559935.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224559935.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224559935.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224559935.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118224559935.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118224559935.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>回到freessl页面，点击配置完成（可能有30分钟左右延迟），检测一下，当检测通过，点击验证即可签发证书，证书签发以后，可以使用https访问一下自己的域名，可以看到证书是有效的</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118230001432.png" title="/images/Trojan-go搭建/image-20210118230001432.png" data-thumbnail="/images/Trojan-go搭建/image-20210118230001432.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118230001432.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118230001432.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118230001432.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118230001432.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118230001432.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h2 id="torjan-go搭建">Torjan-go搭建</h2>
<p><strong>此处我使用的是Centos7的系统</strong></p>
<p>首先安装依赖包</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-shell" data-lang="shell">yum update -y <span class="o">&amp;&amp;</span> yum install -y curl
</code></pre></td></tr></table>
</div>
</div><h3 id="安装bbr加速">安装BBR加速</h3>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-shell" data-lang="shell">wget -N --no-check-certificate <span class="s2">&#34;https://raw.githubusercontent.com/chiakge/Linux-NetSpeed/master/tcp.sh&#34;</span> <span class="o">&amp;&amp;</span> chmod +x tcp.sh <span class="o">&amp;&amp;</span> ./tcp.sh
</code></pre></td></tr></table>
</div>
</div><p>选择需要的BBR加速内核，我的服务器默认已经安装了BBR内核，因此我直接选择4开启</p>
<h3 id="一键安装trojan-go">一键安装trojan-go</h3>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-shell" data-lang="shell"><span class="c1">#安装/更新</span>
<span class="nb">source</span> &lt;<span class="o">(</span>curl -sL https://git.io/trojan-install<span class="o">)</span>
</code></pre></td></tr></table>
</div>
</div><p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123221848951.png" title="/images/Trojan-go搭建/image-20210123221848951.png" data-thumbnail="/images/Trojan-go搭建/image-20210123221848951.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123221848951.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123221848951.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123221848951.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123221848951.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123221848951.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>根据提示安装完毕后，可以使用<code>trojan</code>执行管理管理</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123222315968.png" title="/images/Trojan-go搭建/image-20210123222315968.png" data-thumbnail="/images/Trojan-go搭建/image-20210123222315968.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123222315968.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123222315968.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123222315968.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123222315968.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123222315968.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>或者通过域名在web端进行管理，可以查看当前负载以及添加和用户管理（admin密码可以通过上一图的web管理进行重置）</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123223732652.png" title="/images/Trojan-go搭建/image-20210123223732652.png" data-thumbnail="/images/Trojan-go搭建/image-20210123223732652.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123223732652.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123223732652.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123223732652.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123223732652.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123223732652.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-shell" data-lang="shell"><span class="c1">#卸载</span>
<span class="nb">source</span> &lt;<span class="o">(</span>curl -sL https://git.io/trojan-install<span class="o">)</span> --remove
</code></pre></td></tr></table>
</div>
</div><h2 id="cnd加速">CND加速</h2>
<p><strong><font color=#DC143C>此步骤目的为降低网络延迟，不配置也不影响使用，不过墙裂推荐，速度快了不止一倍</font></strong></p>
<p>如果要使用CDN加速，需要将trojan切换为trojan-go（脚本默认搭建为trojan），Trojan协议本身不带加密，安全性依赖外层的TLS。但流量一旦经过CDN，TLS对CDN是透明的。其服务提供者可以对TLS的明文内容进行审查。<strong>如果你使用的是不可信任的CDN（任何在中国大陆注册备案的CDN服务均应被视为不可信任），请务必开启Shadowsocks AEAD对Webosocket流量进行加密，以避免遭到识别和审查。</strong></p>
<h3 id="cloudflare创建反代理加速">cloudflare创建反代理加速</h3>
<p>注册登录<a href="https://www.cloudflare.com/zh-cn/" target="_blank" rel="noopener noreffer">cloudflare</a>，根据提示拿到Cloudflare提供的DNS服务器</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124143858061.png" title="/images/Trojan-go搭建/image-20210124143858061.png" data-thumbnail="/images/Trojan-go搭建/image-20210124143858061.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124143858061.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124143858061.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124143858061.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124143858061.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210124143858061.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>回到域名提供商，将域名的DNS解析到Cloudflare</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124144436859.png" title="/images/Trojan-go搭建/image-20210124144436859.png" data-thumbnail="/images/Trojan-go搭建/image-20210124144436859.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124144436859.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124144436859.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124144436859.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124144436859.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210124144436859.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>配置完成后，可以在cloudflare首页看到域名是有效的，此时如果ping域名的话，是能看到域名解析的ip已经不是vps的ip了</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151006831.png" title="/images/Trojan-go搭建/image-20210124151006831.png" data-thumbnail="/images/Trojan-go搭建/image-20210124151006831.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151006831.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151006831.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151006831.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151006831.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210124151006831.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h3 id="开启cdn并设置cdn">开启CDN，并设置CDN</h3>
<p>点击DNS，代理状态为黄色，表示代理成功</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153827226.png" title="/images/Trojan-go搭建/image-20210124153827226.png" data-thumbnail="/images/Trojan-go搭建/image-20210124153827226.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153827226.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153827226.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153827226.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153827226.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210124153827226.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>点击页面中的 SSL/TLS 进入如下界面并设置如图所示：（<strong>重要</strong>）</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153922483.png" title="/images/Trojan-go搭建/image-20210124153922483.png" data-thumbnail="/images/Trojan-go搭建/image-20210124153922483.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153922483.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153922483.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153922483.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124153922483.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210124153922483.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h3 id="websocket开启">websocket开启</h3>
<p>若是需要Trojan套用CDN，也就是必须开启 websocket</p>
<p>首先找到trojan-go的配置文件，然后进行备份</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151711839.png" title="/images/Trojan-go搭建/image-20210124151711839.png" data-thumbnail="/images/Trojan-go搭建/image-20210124151711839.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151711839.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151711839.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151711839.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124151711839.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210124151711839.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<p>在配置文件下面添加这2段，更多配置详情见<a href="https://p4gefau1t.github.io/trojan-go/" target="_blank" rel="noopener noreffer">trojan-go官方文档</a></p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span><span class="lnt">3
</span><span class="lnt">4
</span><span class="lnt">5
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-shell" data-lang="shell">    <span class="s2">&#34;websocket&#34;</span>: <span class="o">{</span>
        <span class="s2">&#34;enabled&#34;</span>: true,
        <span class="s2">&#34;path&#34;</span>: <span class="s2">&#34;/DFE4545DFDED/&#34;</span>,
        <span class="s2">&#34;host&#34;</span>: <span class="s2">&#34;域名&#34;</span>
    <span class="o">}</span>
</code></pre></td></tr></table>
</div>
</div><p><code>host</code>是主机名，一般填写域名。客户端<code>host</code>是可选的，填写你的域名。如果留空，将会使用<code>remote_addr</code>填充。</p>
<p><code>path</code>指的是websocket所在的URL路径，必须以斜杠(&quot;/&quot;)开始。路径并无特别要求，满足URL基本格式即可，但要保证客户端和服务端的<code>path</code>一致。<code>path</code>应当选择较长的字符串，以避免遭到GFW直接的主动探测。</p>
<p>客户端的<code>host</code>将包含在Websocket的握手HTTP请求中，发送给CDN服务器，必须有效；服务端和客户端<code>path</code>必须一致，否则Websocket握手无法进行。</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span><span class="lnt">3
</span><span class="lnt">4
</span><span class="lnt">5
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-shell" data-lang="shell">    <span class="s2">&#34;mux&#34;</span>: <span class="o">{</span>
        <span class="s2">&#34;enabled&#34;</span>: true,
        <span class="s2">&#34;concurrency&#34;</span>: 8,
        <span class="s2">&#34;idle_timeout&#34;</span>: <span class="m">60</span>
    <span class="o">}</span>
</code></pre></td></tr></table>
</div>
</div><p>启用多路复用不会增加你的链路速度（甚至会有所减少），而且可能会增加服务器和客户端的计算负担。可以粗略地理解为，多路复用牺牲网络吞吐和CPU功耗，换取更低的延迟。在高并发的情景下，如浏览含有大量图片的网页时，或者发送大量UDP请求时，可以提升使用体验。</p>
<p><code>concurrency</code>是每个TLS连接最多可以承载的TCP连接数。这个数值越大，每个TLS连接被复用的程度就更高，握手导致的延迟越低。但服务器和客户端的计算负担也会越大，这有可能使你的网络吞吐量降低。如果你的线路的TLS握手极端缓慢，你可以将这个数值设置为-1，Trojan-Go将只进行一次TLS握手，只使用唯一的一条TLS连接进行传输。</p>
<p><code>idle_timeout</code>指的是每个TLS连接空闲多长时间后关闭。设置超时时间，<strong>可能</strong>有助于减少不必要的长连接存活确认(Keep Alive)流量传输引发GFW的探测。你可以将这个数值设置为-1，TLS连接在空闲时将被立即关闭。</p>
<h3 id="windows客户端配置">windows客户端配置</h3>
<p>编辑连接，勾选Mux，Type选择ws，<code>host</code>和<code>Path</code>和服务端配置文件保持一致</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124160115672.png" title="/images/Trojan-go搭建/image-20210124160115672.png" data-thumbnail="/images/Trojan-go搭建/image-20210124160115672.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124160115672.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124160115672.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124160115672.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210124160115672.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210124160115672.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h2 id="windows配置">windows配置</h2>
<h3 id="qv2ray及插件安装">Qv2ray及插件安装</h3>
<p><a href="https://github.com/Qv2ray/Qv2ray/releases" target="_blank" rel="noopener noreffer">官网</a>下载最新版本,以及trojan-go插件QvPlugin-Trojan-Go，插件放置在Qv2ray安装目录的plugins目录下，启动Qv2ray的时候会自动加载插件</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224053302.png" title="/images/Trojan-go搭建/image-20210123224053302.png" data-thumbnail="/images/Trojan-go搭建/image-20210123224053302.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224053302.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224053302.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224053302.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224053302.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123224053302.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h3 id="trojan-go核心下载">trojan-go核心下载</h3>
<p><a href="https://github.com/p4gefau1t/trojan-go/releases" target="_blank" rel="noopener noreffer">官网</a>下载最新版本，为了方便管理，在Qv2ray安装目录下创建了个<code>trojan-go</code>目录，将文件放置在此处</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224446229.png" title="/images/Trojan-go搭建/image-20210123224446229.png" data-thumbnail="/images/Trojan-go搭建/image-20210123224446229.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224446229.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224446229.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224446229.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224446229.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123224446229.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h3 id="v2ray-core下载">v2ray-core下载</h3>
<p><a href="https://github.com/v2ray/v2ray-core/releases" target="_blank" rel="noopener noreffer">官网</a>下载最新版本，为了方便管理，在Qv2ray安装目录下创建了个<code>core</code>目录，将文件放置在此处</p>
<h3 id="qv2ray配置">Qv2ray配置</h3>
<h4 id="插件配置">插件配置</h4>
<p>运行Qv2ray客户端，点击插件，选择插件QvPlugin-Trojan-Go，点击设定，点击Browser，选择上一步下载的trojan-go核心</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224726095.png" title="/images/Trojan-go搭建/image-20210123224726095.png" data-thumbnail="/images/Trojan-go搭建/image-20210123224726095.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224726095.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224726095.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224726095.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123224726095.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123224726095.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h4 id="v2ray-core配置">v2ray-core配置</h4>
<p>点击首选项，选择内核设置，选择上一步下载的v2ray-core</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231421131.png" title="/images/Trojan-go搭建/image-20210123231421131.png" data-thumbnail="/images/Trojan-go搭建/image-20210123231421131.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231421131.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231421131.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231421131.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231421131.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123231421131.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h4 id="新建连接">新建连接</h4>
<p>点击新建，配置如图</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231733004.png" title="/images/Trojan-go搭建/image-20210123231733004.png" data-thumbnail="/images/Trojan-go搭建/image-20210123231733004.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231733004.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231733004.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231733004.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210123231733004.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210123231733004.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h3 id="验证">验证</h3>
<p>访问google，能正常访问，Qv2ray能看到访问的日志，搭建成功</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231650953.png" title="/images/Trojan-go搭建/image-20210118231650953.png" data-thumbnail="/images/Trojan-go搭建/image-20210118231650953.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231650953.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231650953.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231650953.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231650953.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118231650953.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h2 id="安卓配置">安卓配置</h2>
<p>下载Trojan安卓客户端（一般选择*-universal-release.apk）<a href="https://github.com/trojan-gfw/igniter/releases" target="_blank" rel="noopener noreffer">https://github.com/trojan-gfw/igniter/releases</a>，安装到手机即可。如果是使用trojan-go的建议使用trojan-go的安卓客户端，速度会比原版快很多。</p>
<p><figure><a class="lightgallery" href="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231237972.png" title="/images/Trojan-go搭建/image-20210118231237972.png" data-thumbnail="/images/Trojan-go搭建/image-20210118231237972.png" data-sub-html="<h2> </h2>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231237972.png"
            data-srcset="/images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231237972.png, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231237972.png 1.5x, /images/Trojan-go%e6%90%ad%e5%bb%ba/image-20210118231237972.png 2x"
            data-sizes="auto"
            alt="/images/Trojan-go搭建/image-20210118231237972.png" />
    </a><figcaption class="image-caption"> </figcaption>
    </figure></p>
<h2 id="相关软件">相关软件</h2>
<p>如果软件下载不方便可以从百度云下载，上传的软件不会再更新了，如果能在gitbub下载，尽量去gitbub下载新版</p>
<p>链接: <a href="https://pan.baidu.com/s/1uKDzaBgt01iY4a15AQHwhg" target="_blank" rel="noopener noreffer">https://pan.baidu.com/s/1uKDzaBgt01iY4a15AQHwhg</a> 提取码: tjhi</p></div><div class="post-footer" id="post-footer">
    <div class="post-info">
        <div class="post-info-line">
            <div class="post-info-mod">
                <span>更新于 2021-01-23</span>
            </div>
            <div class="post-info-license"></div>
        </div>
        <div class="post-info-line">
            <div class="post-info-md"><span>
                            <a class="link-to-markdown" href="/trojan-go%E6%90%AD%E5%BB%BA/index.md" target="_blank">阅读原始文档</a>
                        </span></div>
            <div class="post-info-share">
                <span><a href="javascript:void(0);" title="分享到 Twitter" data-sharer="twitter" data-url="https://guohailan.github.io/trojan-go%E6%90%AD%E5%BB%BA/" data-title="Trojan-go搭建" data-hashtags="torjan"><i class="fab fa-twitter fa-fw"></i></a><a href="javascript:void(0);" title="分享到 Facebook" data-sharer="facebook" data-url="https://guohailan.github.io/trojan-go%E6%90%AD%E5%BB%BA/" data-hashtag="torjan"><i class="fab fa-facebook-square fa-fw"></i></a><a href="javascript:void(0);" title="分享到 Hacker News" data-sharer="hackernews" data-url="https://guohailan.github.io/trojan-go%E6%90%AD%E5%BB%BA/" data-title="Trojan-go搭建"><i class="fab fa-hacker-news fa-fw"></i></a><a href="javascript:void(0);" title="分享到 微博" data-sharer="weibo" data-url="https://guohailan.github.io/trojan-go%E6%90%AD%E5%BB%BA/" data-title="Trojan-go搭建" data-image="/images/thumbnail/trojan-go.png"><i class="fab fa-weibo fa-fw"></i></a><a href="javascript:void(0);" title="分享到 百度" data-sharer="baidu" data-url="https://guohailan.github.io/trojan-go%E6%90%AD%E5%BB%BA/" data-title="Trojan-go搭建"><i data-svg-src="/lib/simple-icons/icons/baidu.min.svg"></i></a></span>
            </div>
        </div>
    </div>

    <div class="post-info-more">
        <section class="post-tags"><i class="fas fa-tags fa-fw"></i>&nbsp;<a href="/tags/torjan/">torjan</a></section>
        <section>
            <span><a href="javascript:void(0);" onclick="window.history.back();">返回</a></span>&nbsp;|&nbsp;<span><a href="/">主页</a></span>
        </section>
    </div>

    <div class="post-nav"><a href="/trojan%E6%90%AD%E5%BB%BA/" class="prev" rel="prev" title="Trojan搭建"><i class="fas fa-angle-left fa-fw"></i>Trojan搭建</a></div>
</div>
<div id="comments"><div id="valine" class="comment"></div><noscript>
                Please enable JavaScript to view the comments powered by <a href="https://valine.js.org/">Valine</a>.
            </noscript></div></article></div>
            </main><footer class="footer">
        <div class="footer-container"><div class="footer-line"><i class="far fa-copyright fa-fw"></i><span itemprop="copyrightYear">2020 - 2021</span><span class="author" itemprop="copyrightHolder">&nbsp;<a href="/" target="_blank">guohailan</a></span>&nbsp;|&nbsp;<span class="license"><a rel="license external nofollow noopener noreffer" href="https://creativecommons.org/licenses/by-nc/4.0/" target="_blank">CC BY-NC 4.0</a></span></div>
        </div>
    </footer></div>

        <div id="fixed-buttons"><a href="#" id="back-to-top" class="fixed-button" title="回到顶部">
                <i class="fas fa-arrow-up fa-fw"></i>
            </a><a href="#" id="view-comments" class="fixed-button" title="查看评论">
                <i class="fas fa-comment fa-fw"></i>
            </a>
        </div><link rel="stylesheet" href="/lib/valine/valine.min.css"><link rel="stylesheet" href="/lib/lightgallery/lightgallery.min.css"><link rel="stylesheet" href="/lib/katex/katex.min.css"><link rel="stylesheet" href="/lib/katex/copy-tex.min.css"><script type="text/javascript" src="/lib/valine/Valine.min.js"></script><script type="text/javascript" src="/lib/smooth-scroll/smooth-scroll.min.js"></script><script type="text/javascript" src="/lib/autocomplete/autocomplete.min.js"></script><script type="text/javascript" src="/lib/lunr/lunr.min.js"></script><script type="text/javascript" src="/lib/lunr/lunr.stemmer.support.min.js"></script><script type="text/javascript" src="/lib/lunr/lunr.zh.min.js"></script><script type="text/javascript" src="/lib/lazysizes/lazysizes.min.js"></script><script type="text/javascript" src="/lib/twemoji/twemoji.min.js"></script><script type="text/javascript" src="/lib/lightgallery/lightgallery.min.js"></script><script type="text/javascript" src="/lib/lightgallery/lg-thumbnail.min.js"></script><script type="text/javascript" src="/lib/lightgallery/lg-zoom.min.js"></script><script type="text/javascript" src="/lib/clipboard/clipboard.min.js"></script><script type="text/javascript" src="/lib/sharer/sharer.min.js"></script><script type="text/javascript" src="/lib/typeit/typeit.min.js"></script><script type="text/javascript" src="/lib/katex/katex.min.js"></script><script type="text/javascript" src="/lib/katex/auto-render.min.js"></script><script type="text/javascript" src="/lib/katex/copy-tex.min.js"></script><script type="text/javascript" src="/lib/katex/mhchem.min.js"></script><script type="text/javascript">window.config={"code":{"copyTitle":"复制到剪贴板","maxShownLines":10},"comment":{"valine":{"appId":"fok8VPlm0I0mJLCDA5SMvn1o-gzGzoHsz","appKey":"Ghs1UwIPIu4r6tEHw1jLYSFG","avatar":"mp","el":"#valine","emojiCDN":"https://cdn.jsdelivr.net/npm/emoji-datasource-google@5.0.1/img/google/64/","emojiMaps":{"100":"1f4af.png","alien":"1f47d.png","anger":"1f4a2.png","angry":"1f620.png","anguished":"1f627.png","astonished":"1f632.png","black_heart":"1f5a4.png","blue_heart":"1f499.png","blush":"1f60a.png","bomb":"1f4a3.png","boom":"1f4a5.png","broken_heart":"1f494.png","brown_heart":"1f90e.png","clown_face":"1f921.png","cold_face":"1f976.png","cold_sweat":"1f630.png","confounded":"1f616.png","confused":"1f615.png","cry":"1f622.png","crying_cat_face":"1f63f.png","cupid":"1f498.png","dash":"1f4a8.png","disappointed":"1f61e.png","disappointed_relieved":"1f625.png","dizzy":"1f4ab.png","dizzy_face":"1f635.png","drooling_face":"1f924.png","exploding_head":"1f92f.png","expressionless":"1f611.png","face_vomiting":"1f92e.png","face_with_cowboy_hat":"1f920.png","face_with_hand_over_mouth":"1f92d.png","face_with_head_bandage":"1f915.png","face_with_monocle":"1f9d0.png","face_with_raised_eyebrow":"1f928.png","face_with_rolling_eyes":"1f644.png","face_with_symbols_on_mouth":"1f92c.png","face_with_thermometer":"1f912.png","fearful":"1f628.png","flushed":"1f633.png","frowning":"1f626.png","ghost":"1f47b.png","gift_heart":"1f49d.png","green_heart":"1f49a.png","grimacing":"1f62c.png","grin":"1f601.png","grinning":"1f600.png","hankey":"1f4a9.png","hear_no_evil":"1f649.png","heart":"2764-fe0f.png","heart_decoration":"1f49f.png","heart_eyes":"1f60d.png","heart_eyes_cat":"1f63b.png","heartbeat":"1f493.png","heartpulse":"1f497.png","heavy_heart_exclamation_mark_ornament":"2763-fe0f.png","hole":"1f573-fe0f.png","hot_face":"1f975.png","hugging_face":"1f917.png","hushed":"1f62f.png","imp":"1f47f.png","innocent":"1f607.png","japanese_goblin":"1f47a.png","japanese_ogre":"1f479.png","joy":"1f602.png","joy_cat":"1f639.png","kiss":"1f48b.png","kissing":"1f617.png","kissing_cat":"1f63d.png","kissing_closed_eyes":"1f61a.png","kissing_heart":"1f618.png","kissing_smiling_eyes":"1f619.png","laughing":"1f606.png","left_speech_bubble":"1f5e8-fe0f.png","love_letter":"1f48c.png","lying_face":"1f925.png","mask":"1f637.png","money_mouth_face":"1f911.png","nauseated_face":"1f922.png","nerd_face":"1f913.png","neutral_face":"1f610.png","no_mouth":"1f636.png","open_mouth":"1f62e.png","orange_heart":"1f9e1.png","partying_face":"1f973.png","pensive":"1f614.png","persevere":"1f623.png","pleading_face":"1f97a.png","pouting_cat":"1f63e.png","purple_heart":"1f49c.png","rage":"1f621.png","relaxed":"263a-fe0f.png","relieved":"1f60c.png","revolving_hearts":"1f49e.png","right_anger_bubble":"1f5ef-fe0f.png","robot_face":"1f916.png","rolling_on_the_floor_laughing":"1f923.png","scream":"1f631.png","scream_cat":"1f640.png","see_no_evil":"1f648.png","shushing_face":"1f92b.png","skull":"1f480.png","skull_and_crossbones":"2620-fe0f.png","sleeping":"1f634.png","sleepy":"1f62a.png","slightly_frowning_face":"1f641.png","slightly_smiling_face":"1f642.png","smile":"1f604.png","smile_cat":"1f638.png","smiley":"1f603.png","smiley_cat":"1f63a.png","smiling_face_with_3_hearts":"1f970.png","smiling_imp":"1f608.png","smirk":"1f60f.png","smirk_cat":"1f63c.png","sneezing_face":"1f927.png","sob":"1f62d.png","space_invader":"1f47e.png","sparkling_heart":"1f496.png","speak_no_evil":"1f64a.png","speech_balloon":"1f4ac.png","star-struck":"1f929.png","stuck_out_tongue":"1f61b.png","stuck_out_tongue_closed_eyes":"1f61d.png","stuck_out_tongue_winking_eye":"1f61c.png","sunglasses":"1f60e.png","sweat":"1f613.png","sweat_drops":"1f4a6.png","sweat_smile":"1f605.png","thinking_face":"1f914.png","thought_balloon":"1f4ad.png","tired_face":"1f62b.png","triumph":"1f624.png","two_hearts":"1f495.png","unamused":"1f612.png","upside_down_face":"1f643.png","weary":"1f629.png","white_frowning_face":"2639-fe0f.png","white_heart":"1f90d.png","wink":"1f609.png","woozy_face":"1f974.png","worried":"1f61f.png","yawning_face":"1f971.png","yellow_heart":"1f49b.png","yum":"1f60b.png","zany_face":"1f92a.png","zipper_mouth_face":"1f910.png","zzz":"1f4a4.png"},"enableQQ":false,"highlight":true,"lang":"zh-cn","pageSize":10,"placeholder":"说些什么...","recordIP":true,"serverURLs":"https://fok8vplm.lc-cn-n1-shared.com","visitor":true}},"data":{"id-1":"My blog","id-2":"My blog"},"lightGallery":{"actualSize":false,"exThumbImage":"data-thumbnail","hideBarsDelay":2000,"selector":".lightgallery","speed":400,"thumbContHeight":80,"thumbWidth":80,"thumbnail":true},"math":{"delimiters":[{"display":true,"left":"$$","right":"$$"},{"display":true,"left":"\\[","right":"\\]"},{"display":false,"left":"$","right":"$"},{"display":false,"left":"\\(","right":"\\)"}],"strict":false},"search":{"highlightTag":"em","lunrIndexURL":"/index.json","lunrLanguageCode":"zh","lunrSegmentitURL":"/lib/lunr/lunr.segmentit.js","maxResultLength":10,"noResultsFound":"没有找到结果","snippetLength":50,"type":"lunr"},"twemoji":true,"typeit":{"cursorChar":"|","cursorSpeed":1000,"data":{"id-1":["id-1"],"id-2":["id-2"]},"duration":-1,"speed":100}};</script><script type="text/javascript" src="/js/theme.min.js"></script></body>
</html>
